import autoImport from "unplugin-auto-import/vite"; //文档地址 https://gitcode.com/gh_mirrors/unp/unplugin-auto-import/?utm_source=outstanding_ugc_gitcode&index=bottom&type=card&webUrl=

autoImport({
  imports: [
    "react",
    "react-router-dom",
    "jotai",
    {
      clsx: [["default", "clsx"]],
    },
    {
      "src/client/components/SvgIcon": ["SvgIcon"],
    },
  ],
  dirs: ["src/client/api", "src/shared/url-map"],
  dts: "./src/types/auto-imports.d.ts",
  // 解决eslint报错问题
  eslintrc: {
    // 这里先设置成true然后npm run dev 运行之后会生成 .eslintrc-auto-import.json 文件之后，在改为false
    enabled: true,
    filepath: "./.eslintrc-auto-import.json", // 生成的文件路径
    globalsPropValue: true,
  },
});
